Skip to content

chore: move pnpm overrides from package.json to pnpm-workspace.yaml#27043

Draft
alexvy86 wants to merge 1 commit intomicrosoft:mainfrom
alexvy86:move-pnpm-overrides-to-workspace-yaml
Draft

chore: move pnpm overrides from package.json to pnpm-workspace.yaml#27043
alexvy86 wants to merge 1 commit intomicrosoft:mainfrom
alexvy86:move-pnpm-overrides-to-workspace-yaml

Conversation

@alexvy86
Copy link
Copy Markdown
Contributor

@alexvy86 alexvy86 commented Apr 14, 2026

Description

pnpm v10 supports overrides natively in pnpm-workspace.yaml, which is their canonical location going forward. This moves all pnpm.overrides entries and their associated comment arrays from package.json to the corresponding pnpm-workspace.yaml across all 14 workspaces.

  • YAML comments replace the JSON comment arrays (comments, commentsOverrides, overrideComments, overridesComments) so override documentation is preserved inline next to each override
  • Where onlyBuiltDependencies was already duplicated between package.json and pnpm-workspace.yaml, the package.json copy is removed since the yaml is the authoritative source
  • Each workspace was independently validated with pnpm install --frozen-lockfile — all no-ops, no lockfile changes

28 files changed across 14 workspaces (14 package.json + 14 pnpm-workspace.yaml), 298 override entries moved total.

Reviewer Guidance

The review process is outlined on this wiki page.

This is a pure config migration — no code changes. The best way to verify is to confirm pnpm install --frozen-lockfile is a no-op in each workspace after the change.

pnpm v10 supports overrides natively in pnpm-workspace.yaml, which is
their canonical location going forward. This moves all `pnpm.overrides`
entries and their associated comment arrays from package.json to the
corresponding pnpm-workspace.yaml across all 14 workspaces.

YAML comments replace the JSON comment arrays (comments, commentsOverrides,
overrideComments, overridesComments) so the documentation for each override
is preserved inline next to the override it describes.

Where onlyBuiltDependencies was already duplicated between package.json
and pnpm-workspace.yaml, the package.json copy is removed since the yaml
is the authoritative source.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@alexvy86 alexvy86 changed the title Move pnpm overrides from package.json to pnpm-workspace.yaml chore: move pnpm overrides from package.json to pnpm-workspace.yaml Apr 14, 2026
@alexvy86
Copy link
Copy Markdown
Contributor Author

alexvy86 commented Apr 14, 2026

I'd like to move forward with this to get better support for comments for overrides, but right now Syncpack doesn't support looking at versions in pnpm-workspace.yaml, so we would be losing that bit of validation, so it's not a trivial trade-off.

Issues tracking this or related functionality:

@github-actions
Copy link
Copy Markdown
Contributor

🔗 No broken links found! ✅

Your attention to detail is admirable.

linkcheck output


> fluid-framework-docs-site@0.0.0 ci:check-links /home/runner/work/FluidFramework/FluidFramework/docs
> start-server-and-test "npm run serve -- --no-open" 3000 check-links

1: starting server using command "npm run serve -- --no-open"
and when url "[ 'http://127.0.0.1:3000' ]" is responding with HTTP status code 200
running tests using command "npm run check-links"


> fluid-framework-docs-site@0.0.0 serve
> docusaurus serve --no-open

[SUCCESS] Serving "build" directory at: http://localhost:3000/

> fluid-framework-docs-site@0.0.0 check-links
> linkcheck http://localhost:3000 --skip-file skipped-urls.txt

Crawling...

Stats:
  279037 links
    1880 destination URLs
    2126 URLs ignored
       0 warnings
       0 errors


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant